import request from '@/plugin/axios'
// 获取列表
export function getgrouppage(params) {
    return request({
        url: '/upms/group/page',
        method: 'get',
        params: request.adornParams(params)
    })
}
// 获取列表
export function getgrouplist(params) {
    return request({
        url: '/upms/group/list',
        method: 'get',
        params: request.adornParams(params)
    })
}
// 获取集团列表字典
export function getgrouplistdict() {
    return request({
        url: '/upms/group/dict',
        method: 'get',
        params: request.adornParams({})
    })
}
// 获取集团字典树
export function getgroupsimpletree() {
    return request({
        url: '/upms/group/simple/tree',
        method: 'get',
        params: request.adornParams({})
    })
}
// 获取列表树
export function getgrouptree(params) {
    return request({
        url: '/upms/group/tree',
        method: 'get',
        params: request.adornParams(params)
    })
}
// 获取信息
export function getgroupinfo(id) {
    return request({
        url: '/upms/group/info/' + id,
        method: 'get',
        params: request.adornParams({})
    })
}

// 添加
export function addgroup(data) {
    return request({
        url: '/upms/group/save',
        method: 'post',
        data
    })
}

// 修改
export function updategroup(data) {
    return request({
        url: '/upms/group/update',
        method: 'put',
        data
    })
}

// 批量删除
export function delBatchgroup(params) {
    return request({
        url: '/upms/group/delete',
        method: 'delete',
        data: request.adornData(params, false)
    })
}

// 删除
export function delgroup(id) {
    return request({
        url: '/upms/group/delete/' + id,
        method: 'delete',
    })
}

// 数据导出
export function groupExport(params) {
    return request({
        url: '/report/group/export',
        method: 'get',
        params: request.adornParams(params)
    })
}